package com.woniu.mapper;

import com.woniu.pojo.Order;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.ResultType;
import org.apache.ibatis.annotations.Select;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author Yellow Docker
 * @since 2022-11-16
 */
public interface OrderMapper extends BaseMapper<Order> {

    @Select("select oi.shop_id from c_order o ,c_order_item oi where o.id=#{id} and o.id=oi.id ")
    @ResultType(Integer.class)
    Integer getShopId(Integer id);

    int updateOrderStatus(String orderSn);

    int updateStatus(String orderSn);

    int updateStatusPro(String orderSn);
}
